package com.bw.counter.view

import androidx.appcompat.app.AppCompatActivity
import android.os.Bundle
import android.util.Log
import android.view.View
import com.alibaba.android.arouter.facade.annotation.Autowired
import com.alibaba.android.arouter.facade.annotation.Route
import com.alibaba.android.arouter.launcher.ARouter
import com.bw.base.constants.RoutePath
import com.bw.common.view.BaseMvvmActivity
import com.bw.counter.R
import com.bw.counter.databinding.ActivityWuYeDetailBinding
import com.bw.counter.entity.ChargeData
import com.bw.counter.net.CounterViewModel
/**
 *  智慧园区-05-收费详情 -v1.1-张梦停
 *  2025/05/09
 */
@Route(path = RoutePath.PATH_Count_WuYe_Detail)
class WuYeDetailActivity : BaseMvvmActivity<ActivityWuYeDetailBinding,CounterViewModel>() {
    @Autowired
    @JvmField
    var charge : ChargeData?= null

    override fun initView() {
        ARouter.getInstance().inject(this)
        binding.wuyeTop.ivMore.visibility = View.GONE
        binding.wuyeTop.ivBack.setOnClickListener { finish() }
        binding.wuyeTop.tvTitle.text = "收费详情"
        Log.i("-----ss", "initView: ${charge!!.chargeAmount}")
        charge?.apply {
            binding.name.text = this.contactNumber
            binding.tv2.text = this.chargeType
            binding.tv3Time.text = "${this.expirationDate}至${this.effectiveDate}"
            binding.tv4Time.text = "￥${this.chargeAmount}"
            binding.tv5Time.text = "${2}"
            binding.tv6Time.text = "￥${this.chargeAmount * 2}.00"
            binding.tv10Time.text = binding.tv6Time.text
            binding.tv21Time.text = binding.tv10Time.text
            binding.tv24Time.text = binding.tv21Time.text
            binding.tv26Time.text = binding.tv24Time.text
            binding.tv31Time.text = this.paymentMethod
            binding.tv32Time.text = this.paymentTime
            binding.tv33Time.text = this.operator
        }
    }

    override fun initData() {

    }

}